package com.example.safelib.adapter

import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.BaseViewHolder
import com.example.safelib.R
import com.example.safelib.bean.SafeNickBean

/**
 * Author: sxygsj
 * Date: 2020/8/25 9:32
 * Description:
 * History:
 * <author> <time> <version> <desc>
 * 作者姓名 修改时间 版本号 描述
 */
class SafeAllNickAdapter (layoutResId: Int) :
    BaseQuickAdapter<SafeNickBean, BaseViewHolder>(layoutResId) {
    override fun convert(helper: BaseViewHolder, item: SafeNickBean) {
        helper.setText(R.id.safe_nickname,(helper.adapterPosition+1).toString()+"-"+item.minename).setText(R.id.safe_nick_online,item.netState)
            .setText(R.id.safe_nick_kglno,item.kglno).setText(R.id.safe_nick_mnlno,item.mnlno)
            .setText(R.id.safe_nick_alno,item.alno).setText(R.id.safe_nick_dalno,item.dalno)
            .setText(R.id.safe_nick_date,item.datatime)
    }
}